<?

$fs_inv_ctl_purchase_order_entry = new Fieldset (array (
	db_conn=>$_GLOBAL_DBH,
	relation=>"inv_ctl_purchase_order_entry",
	title=>"Inventory Purchase Order Entry",
	fieldset=>array (
		array (name=>"id",label=>"ID",type=>"numeric",
				value=>$_REQUEST["purchase_order_entry_id"],
				input=>"hidden",primary_key=>true),
		array (name=>"item_id",label=>"Item",type=>"any",
				relation=>array(foreign=>"inv_ctl_items",key=>"id",
				field=>"name"),
				input=>"select",
				options=>"_app_select_query",
				options_params=>"SELECT id,name FROM inv_ctl_items",
				columns=>array (key=>"id",value=>"name"),
		),
		array (name=>"purchase_order_id",label=>"Purchase Order ID",type=>"numeric",
				value=>$_REQUEST["purchase_order_id"],
				input=>"hidden"),
		array (name=>"transaction",label=>"Transaction",type=>"alphanumeric",
				input=>"field"),
		array (name=>"transaction_date",label=>"Date Entered",type=>"any",
				input=>"date",value=>_app_date("transaction_date")),
		array (name=>"unit_price",label=>"Unit Price",type=>"decimal",
				input=>"field"),
		array (name=>"units_ordered",label=>"Units Ordered",type=>"numeric",
				input=>"input"),
		array (name=>"units_received",label=>"Units Received",type=>"numeric",
				input=>"input"),
		array (name=>"units_sold",label=>"Units Sold",type=>"numeric",
				input=>"input"),
		array (name=>"units_shrinkage",label=>"Unit Shrinkage",type=>"numeric",
				input=>"input"),
               ),
));

$fs_inv_ctl_purchase_order_entry->parse ();

?>
